package org.homonoia.worker.exceptions;

public class StartupException extends Exception {

    private static final long serialVersionUID = -2823244364667344173L;
    private final Throwable cause;

    public StartupException(String message) {
	super(message);
	this.cause = null;
    }

    public StartupException(String message, Throwable cause) {
	super(message);
	this.cause = cause;
    }

    public String getMessageWithCause() {
	String extra = this.cause == null ? "" : ": " + this.cause.getMessage();
	return getMessage() + extra;
    }

}
